<template>
	<el-col :span="spans">
		<el-form-item :label="labelName" :label-width="GLOBAL.formLabelWidth" :prop="propVal">
			<el-select v-model="val" :placeholder="'请选择'+labelName" style="width: 100%;" @change="selectChange" :disabled="disabled" clearable>
				<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value">
				</el-option>
			</el-select>
		</el-form-item>
	</el-col>
</template>

<script>
	export default {
		props: ['spans','propVal', 'labelName', 'options','value','disabled'],
		data(){
			return{
				val:''
			}
		},
		methods:{
			selectChange(){
				this.$emit('selectEvent',this.val,this.propVal)
			}
		},
		watch:{
			'value':{
				handler(newVal){
					this.val = newVal
				},
				 immediate: true, 
				 deep: true
			},
		}
	}
</script>

<style>
</style>
